(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
'use strict';

$(function () {
    // $('body').addClass('g-loading');
    // http://api-t.chinaqljf.com/broker/brokerInfo?uid=5339
    var c = {
        ajax: '/broker/brokerInfo',
        data: { uid: 5339 }
    };

    function initApp(cb) {
        if (c.data.uid > 0) {
            cb();
        } else {
            XT.getUserInfo(function (info) {
                c.data.uid = info.id;
                cb();
            });
        }
    }

    initApp(function () {
        var store = new Vuex.Store({
            state: {
                data: {
                    higherUserInfo: {},
                    inviteNum: '',
                    directInviteNum: '',
                    indirectInviteNum: '',
                    brokerLevelInfo: [{ level: '', inviteNum: '' }, { level: '', inviteNum: '' }, { level: '', inviteNum: '' }, { level: '', inviteNum: '' }, { level: '', inviteNum: '' }]
                },
                showloading: ''
            },
            actions: {
                'get_information': function get_information(_ref, params) {
                    var commit = _ref.commit,
                        state = _ref.state;

                    XT.jsonp({
                        url: c.ajax,
                        data: params.data,
                        success: function success(data) {
                            // params.callback(data)
                            commit('set_information', data);
                        }
                    });
                }
            },
            mutations: {
                'set_information': function set_information(state, data) {
                    console.log(data.inviteNum);
                    state.data = data;
                    state.showloading = true;
                    console.log(data.brokerLevelInfo);
                }

            }
        });

        var App = new Vue({
            el: '#app',
            store: store,
            data: {},
            methods: {},
            computed: {
                'higherUserInfo': function higherUserInfo() {
                    return this.$store.state.data.higherUserInfo;
                },
                'inviteNum': function inviteNum() {
                    return this.$store.state.data.inviteNum;
                },
                'directInviteNum': function directInviteNum() {
                    return this.$store.state.data.directInviteNum;
                },
                'indirectInviteNum': function indirectInviteNum() {
                    return this.$store.state.data.indirectInviteNum;
                },
                'brokerLevelInfo': function brokerLevelInfo() {
                    return this.$store.state.data.brokerLevelInfo;
                },
                'showloading': function showloading() {
                    return this.$store.state.showloading;
                }
            },
            created: function created() {
                this.$store.dispatch('get_information', {
                    data: c.data
                });
            }
        });
    });
});

},{}]},{},[1]);
